package work;

import java.util.Arrays;

public class MatchDemo {
    public static void main(String[] args) {
        String path = "http://localhost:8088/myweb.reg?name=zhangsan&pwd=123456&nick=san&age=16";

        path.toString();
        path.equals("aaa");

        String str1 = " 123456 ";
        boolean a = str1.trim().matches("[0-9]+");
        System.out.println(a);

        String[] arrPath = path.split("[?&]");
        System.out.println(Arrays.toString(arrPath));

        for(int i=1;i<arrPath.length;i++){
            String str = arrPath[i];
            String[] data=str.split("=");
            System.out.println("参数名："+data[0]+"\t\t参数值："+data[1]);
        }

    }
}
